package com.tudouji.project.produce.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.flow.service.pojo.BasePojo;
import com.flow.service.pojo.flow.FlowTempNode;
import com.tudouji.framework.aspectj.lang.annotation.Excel;
import com.tudouji.framework.web.domain.BaseEntity;
import com.tudouji.project.flow.domain.Flowtempnode;
import com.tudouji.project.purchasebill.domain.Purchasebillitem;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 报废对象 materialretapply
 *
 * @author tudouji
 * @date 2022-06-01
 */
@Data
public class Materialretapply extends BasePojo {
    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    private Long id;
    private Long deptId;
    private String deptName;
    private Long orgId;
    private Long createBy;
    private Long flowid;
    private String[] roomids;
    private String[] depids;

    private Long strmId;

    private String guid;
    private String keyword;
    private String search;
    private String statusname;

    /**
     * 生产计划ID
     */
    @Excel(name = "生产计划ID")
    private String produceplanid;

    /**
     * 生产领料单ID
     */
    @Excel(name = "生产领料单ID")
    private String linkedid;

    /**
     * 库房guid
     */
    @Excel(name = "库房guid")
    private String srguid;

    /**
     * 入库类型
     */
    @Excel(name = "入库类型")
    private Integer type;

    /**
     * 1 待入库
     * 2 已入库
     */
    private Integer status;

    /**
     * 公司ID，从生产计划单获取
     */
    @Excel(name = "公司ID，从生产计划单获取")
    private String orgguid;

    /**
     * 公司名称
     */
    @Excel(name = "公司名称")
    private String orgname;

    /**
     * 班组ID
     */
    @Excel(name = "班组ID")
    private String departid;

    /**
     * 申请人
     */
    @Excel(name = "申请人")
    private String operatorid;

    /**
     * 最后修改时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "最后修改时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date lastupdate;

    /**
     * 库间guid
     */
    @Excel(name = "库间guid")
    private String sthid;

    private String produceplanCode;
    private String linkedCode;
    private String produceplanName;
    private String planstart;
    private String srName;
    private String departName;
    private String operatorName;
    private String typeName;

    /**
     * 编号
     */
    @Excel(name = "编号")
    private String code;

    private Integer[] stats;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createtime;

    private List<Matretapplyitem> items;

    private List<Flowtempnode> nodes;
    private Integer[] notStats;
    public void prepareForProcess(){
        setBusTable("materialretapply");
        setPlatformId(strmId);
    }

}
